import {createRouter,createWebHashHistory } from 'vue-router'
import Home from '../views/home.vue'
import CommonSense from '../views/commonSense.vue'
import Animal from '../views/animal.vue'
import DynamicState from '../views/dynamicState.vue'
import Personal from '../views/personal.vue'
import ArticlePage from '../views/articlePage.vue'
import Ani from '../views/Ani.vue'
const router = createRouter({
  history: createWebHashHistory(),
  routes:[
    {
      path:'/',
      redirect: '/home'
    },
    {
      path:'/home',
      component: Home
    },
    {
      path: '/commonSense',
      component: CommonSense
    },
    {
      path: '/animal',
      component: Animal
    },
    {
      path: '/dynamicState',
      component: DynamicState
    },
    {
      path:'/personal',
      component: Personal
    },
    {
      path: '/article/:id',
      name: "article",
      component: ArticlePage
    },
    {
      path: '/ani/:id',
      name: 'ani',
      component: Ani
    }
  ]
})
export default router